<script setup lang="ts">
defineProps<{
  msg: string
}>()

const emit = defineEmits<{
  (e: 'update:msg', str: string): void
}>()
</script>

<template>
  <div class="a-page">
    {{ msg }}
    <button @click="emit('update:msg', '你变了')">修改文字</button>
  </div>
</template>

<style scoped></style>
